.reset-filter() {
	filter: e(%("progid:DXImageTransform.Microsoft.gradient(enabled = false)"));
}

.gradientBar(@primaryColor, @secondaryColor, @textColor: #fff, @textShadow: 0 -1px 0 rgba(0,0,0,.25)) {
	color: @textColor;
	text-shadow: @textShadow;
	#gradient > .vertical(@primaryColor, @secondaryColor);
	border-color: @secondaryColor @secondaryColor darken(@secondaryColor, 15%);
	border-color: rgba(0,0,0,.1) rgba(0,0,0,.1) fadein(rgba(0,0,0,.1), 15%);
}

// Gradients
#gradient {
	.vertical(@startColor: #555, @endColor: #333) {
		background-color: mix(@startColor, @endColor, 60%);
		background-image: -moz-linear-gradient(top, @startColor, @endColor); // FF 3.6+
		background-image: -webkit-gradient(linear, 0 0, 0 100%, from(@startColor), to(@endColor)); // Safari 4+, Chrome 2+
		background-image: -webkit-linear-gradient(top, @startColor, @endColor); // Safari 5.1+, Chrome 10+
		background-image: -o-linear-gradient(top, @startColor, @endColor); // Opera 11.10
		background-image: linear-gradient(to bottom, @startColor, @endColor); // Standard, IE10
		background-repeat: repeat-x;
		filter: e(%("progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)",argb(@startColor),argb(@endColor))); // IE9 and down
	}
}

.buttonBackground(@startColor, @endColor, @textColor: #fff, @textShadow: 0 -1px 0 rgba(0,0,0,.25)) {
	.gradientBar(@startColor, @endColor, @textColor, @textShadow);
	.reset-filter();

	&:hover, &:focus, &:active, &.active, &.disabled, &[disabled] {
		color: @textColor;
		background-color: @endColor;
	}

	&:active,
	&.active {
		background-color: darken(@endColor, 10%) e("\9");
	}
}

// Drop shadows
.box-shadow(@shadow) {
  -webkit-box-shadow: @shadow;
     -moz-box-shadow: @shadow;
          box-shadow: @shadow;
}